package com.bstek.uflo.designer.utils;

import java.util.Date;
import java.util.concurrent.atomic.AtomicInteger;

public class MemoryIdGenerator {

	private static MemoryIdGenerator generator = new MemoryIdGenerator();

	private MemoryIdGenerator() {
	}

	private AtomicInteger nextId = new AtomicInteger(100);

	public static int nextId() {
		return generator.nextId.incrementAndGet();
	}

	public static String nextKey() {
		return "UFLO_" +new Date().getTime()+"_"+ nextId();
	}

}
